<?php $this->load->view($config['site_template'].'/head');?>
<style type="text/css">
    .table>tbody>tr>td{
        border:2px solid #e7eaec;
    }
</style>

    <body class="gray-bg">

<!--    <div class="row  border-bottom white-bg dashboard-header">-->
<!--        <div class="col-sm-12">-->
<!--            <p>贵州智慧巡检一烧环节 数据推移图-->
<!--            </p>-->
<!---->
<!--        </div>-->
<!---->
<!--    </div>-->
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="row">
            <?php foreach ($productLine as $value):?>
            <div class="col-sm-6">
                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>设备二级点检表推移图(<?=$value['lineName']?>)</h5>
                        <div class="ibox-tools">
                        </div>
                    </div>
                    <div class="ibox-content">
                        <div class="echarts" id="echarts_line_sbejdjb_<?=$value['lineId']?>"></div>
                    </div>
                </div>
            </div>
            <?php endforeach;?>


<!--            <div class="col-sm-6">-->
<!--                <div class="ibox float-e-margins">-->
<!--                    <div class="ibox-title">-->
<!--                        <h5>投料间露点推移图(6号线)</h5>-->
<!--                        <div class="ibox-tools">-->
<!--                                                        <a class="collapse-link">-->
<!--                                                            <i class="fa fa-chevron-up"></i>-->
<!--                                                        </a>-->
<!--                                                        <a class="dropdown-toggle" data-toggle="dropdown" href="graph_flot.html#">-->
<!--                                                            <i class="fa fa-wrench"></i>-->
<!--                                                        </a>-->
<!--                                                        <ul class="dropdown-menu dropdown-user">-->
<!--                                                            <li><a href="graph_flot.html#">选项1</a>-->
<!--                                                            </li>-->
<!--                                                            <li><a href="graph_flot.html#">选项2</a>-->
<!--                                                            </li>-->
<!--                                                        </ul>-->
<!--                                                        <a class="close-link">-->
<!--                                                            <i class="fa fa-times"></i>-->
<!--                                                        </a>-->
<!--                        </div>-->
<!--                    </div>-->
<!--                    <div class="ibox-content">-->
<!--                        <div class="echarts" id="echarts_line_sbejdjb_6"></div>-->
<!--                    </div>-->
<!--                </div>-->
<!--            </div>-->

    </div>
    <script src="<?=$config['site_templateurl'];?>/js/Echarts/echarts.min.js?v=2.1.4"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            //露点推移图
            <?php foreach ($productLine as $val):?>
                var showName_sbejdjb_<?=$val["lineId"]?> = [],showData_sbejdjb_<?=$val["lineId"]?> = [];
                <?php foreach($sbejdjb as $value):?>
                    <?php if($value['productLine'] === $val['lineId']):?>
                        showName_sbejdjb_<?=$val["lineId"]?>.push('<?=$value["year"]."-".$value["month"]."-".$value["day"]." ".$value["hour"]."H"?>');
                        showData_sbejdjb_<?=$val["lineId"]?>.push(<?=$value['oxygenContentValue']?>);
<!--                    --><?php //elseif ($value['productLine'] === "6"):?>
//                        showName_sbejdjb_6.push('<?//=$value["year"]."-".$value["month"]."-".$value["day"]." ".$value["hour"]."H"?>//');
//                        showData_sbejdjb_6.push(<?//=$value['temperature']?>//);
                    <?php endif;?>
                <?php endforeach;?>
                // 基于准备好的dom，初始化echarts实例
                var myChart_sbejdjb_<?=$val["lineId"]?> = echarts.init(document.getElementById('echarts_line_sbejdjb_<?=$val["lineId"]?>'));
                // 指定图表的配置项和数据
                var option_sbejdjb_<?=$val["lineId"]?> = {
                    title: {
                        text: ''
                    },
                    tooltip: {
                        trigger: 'axis'
                    },
                    legend: {
                        data: ['供氧氧含量实时值(%)']
                    },
                    toolbox: {
                        feature: {
                            saveAsImage: {}
                        }
                    },
                    xAxis: {
                        data: showName_sbejdjb_<?=$val["lineId"]?>
                    },
                    yAxis: {},
                    series: [
                        {
                            name: '供氧氧含量实时值(%)',
                            type: 'line',
                            data: showData_sbejdjb_<?=$val["lineId"]?>,
                            smooth: true
                        }
                    ]
                };

                // 使用刚指定的配置项和数据显示图表。
                myChart_sbejdjb_<?=$val["lineId"]?>.setOption(option_sbejdjb_<?=$val["lineId"]?>);
            <?php endforeach;?>
        })

    </script>
    </body>

<?php $this->load->view($config['site_template'].'/foot');?>